<!DOCTYPE html>
<html>
    <head>
        <title>manipulation of elements</title>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <script type="text/javascript" src="jquery-1.9.1.js"></script>
        <script type="text/javascript">
            $(document).ready(function() {
                var speed = 1000;
                $("#moveLeft").click(function() {
                    $("h1").animate({"left": "-=100px"}, speed);
                });
                $("#moveRight").click(function() {
                    $("h1").animate({"left": "+=100px"}, speed);
                });
                $("#moveUp").click(function() {
                    $("h1").animate({"top": "-=100px"}, speed);
                });
                $("#moveDown").click(function() {
                    $("h1").animate({"top": "+=100px"}, speed);
                });
            });
        </script>
    </head>
    <body>
        <h4>
            <a href="index.html">Index</a>
        </h4>
        <input id="moveUp" type="button" value="Move Up" />
        <input id="moveDown" type="button" value="Move Down" />
        <input id="moveLeft" type="button" value="Move Left" />
        <input id="moveRight" type="button" value="Move Right" />
        <h1 style="position: absolute; left: 250px; top: 150px " >Dot</h1>
    </body>
</html>
